package colleague;

import lombok.AllArgsConstructor;
import lombok.Data;
import mediator.Mediator;

@Data
@AllArgsConstructor
public abstract class Person {

    protected String name;
    protected Mediator mediator;

    //和中介联系
    public void contact(String message) {
        mediator.contact(message, this);
    }

    public abstract void getMessage(String message);
}
